<template>
  <div id="payment">
    <div class="login-head">
      <span style="color: #fff" @click="jumpFn()">
        <van-icon name="arrow-left"
      /></span>
      <span class="login-title">在线支付</span>
      <span></span>
    </div>
    <div class="countDown">
      <p class="last-time">支付剩余时间</p>
      <van-count-down :time="time">
        <template #default="timeData">
          <span class="block">{{ timeData.hours }}</span>
          <span class="colon">:</span>
          <span class="block">{{ timeData.minutes }}</span>
          <span class="colon">:</span>
          <span class="block">{{ timeData.seconds }}</span>
        </template>
      </van-count-down>
    </div>
      
    <p class="choose-pay">请选择支付方式</p>
    <van-radio-group v-model="radio"> 
    <div class="result-pay">
      <div class="result-pay-list" style="border-bottom:1px solid #f1f1f1">
        <div class="result-pay-list-left">
          <div class="zfb"></div>
          <p style="font-size: 16px; color: #666">支付宝</p>
        </div>
        <div class="result-pay-list-right">
           <van-radio name="1" checked-color="#4cd964" icon-size="23px"></van-radio>
        </div>
      </div>
      <div class="result-pay-list">
        <div class="result-pay-list-left">
          <div class="zfb"></div>
          <p style="font-size: 16px; color: #666">微信</p>
        </div>
        <div class="result-pay-list-right">
             <van-radio name="2" checked-color="#4cd964" icon-size="23px"></van-radio>
        </div>
      </div>
    </div>
   </van-radio-group>
   <div class="foot-btn">
       <van-button type="primary" class="wink" @click="tip()">确认支付</van-button>
   </div>
   
  </div>
</template>

<script>
export default {
  name: "payment",

  data() {
    return {
      time: 60 * 15 * 1000,
       radio: '1'
    };
  },
  mounted() {},
  methods: {
    jumpFn() {
      this.$router.push({
        name: "vipCenter",
      });
    },
    tip(){
          $(".wink").attr("id", "tip");
          new TipBox({ type: "tip", str: "当前环境无法支付", hasBtn: true });
    }
  },
};
</script>

<style scoped>
.result-pay-list{
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 79px;
    box-sizing: border-box;
    padding: 0 15px;
    background-color: #fff;
}
.foot-btn button{
    width: 95%;
}
.foot-btn{
    text-align: center;
    margin-top: 10px;
}
.result-pay-list-left {
  display: flex;
  align-items: center;
}

.login-head {
  width: 100%;
  height: 1.2576rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: #0092e8;
}
.login-title {
  color: white;
  position: relative;
  left: -0.5405rem;
  font-size: 0.5405rem;
}
.block,
.colon {
  font-size: 35px;
}
.last-time {
  text-align: center;
  font-size: 16px;
  font-size: #666;
  margin-top: 44px;
  margin-bottom: 22px;
}

.zfb {
  width: 47px;
  height: 47px;
  background: url()
    no-repeat;
  background-size: 100% 100%;
}
.countDown {
  width: 100%;
  height: 147.5px;
  text-align: center;
  font-size: 50px;
  display: flex;
  flex-direction: column;
  /* justify-content: space-around; */
  align-items: center;
}
#payment {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 2;
  width: 100%;
  height: 100%;
  background-color: #f5f5f5;
}
.choose-pay {
  width: 100%;
  line-height: 42px;
  padding: 0 15px;
  box-sizing: border-box;
  font-size: 16.5px;
  color: #666;
  background-color: #f1f1f1;
}
</style>